package com.njwb.subject;

import com.njwb.subject.service.SubjectService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;

@SpringBootApplication
public class SubjectServiceApplication {


    public static void main(String[] args) {
        SpringApplication.run(SubjectServiceApplication.class, args);
    }

    //系统启动的时候将数据加载到redis中
    @Autowired
    public void load(SubjectService subjectService){
        subjectService.load();
    }

}
